Release 10.1A: OpenEdge Development:
Java Open Clients
Property interface
A Java SDO
Propertyis contained in a property list associated with aDataObject, where each property in the list has a well defined index. In theProDataGraphmodel, aPropertycorresponds to either a temp-table field (as a column property) or references anotherDataObject(as a reference property). A column property has aTypethat is either a primitive type, such asint, or a commonly used class, such asjava.lang.String. A reference property has aTypethat refers to theTypeof anotherDataObject. For example, the reference property of aDataObjectof data typeCustomermight refer to one or moreDataObjectinstances of data typeOrder.A column property can be single-valued or many-valued. If a Progress 4GL temp-table field is defined with an extent option, its corresponding column property is defined as many-valued.
In the
ProDataGraphmodel, a reference property is used to implement a data-relation defined by an associatedProDataRelationMetaDataobject. When you invoke theProDataGraphsetChildReferences()method, a reference property is added to eachDataObjectof every parent table that references a child tableDataObject. A reference property is defined as many-valued so multiple childDataObjectinstances of the same type can be referenced in a given child table.Methods
The Java SDO
Propertyinterface provides these methods:
- getName( ) — This method returns the name of the
Property. For a column property, this is the 4GL name of the corresponding temp-table field:
- getType( ) — This method returns the
Typeof theProperty:
- isMany( ) — This method returns
trueif thisPropertyis defined as many-valued, andfalseif single-valued. If it returnstruefor a column property, theDataObjectget*()methods return ajava.lang.List. It always returnstruefor a reference property:
- getDefault( ) — This method returns the default value this
Propertyhas in aDataObject(as specified by Java SDO) when the property has not yet been set:
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |